#!/usr/bin/env python
# coding=utf-8
"""
# @Created on : 2016/05/05 21:10
# @Author     : ldf (ldf@eehello.com)
# @Link       : http://www.eehello.com
# @Version    : 
# 本程序在python2.7下测试通过
"""


#!/usr/bin/env python
# coding=utf-8
'''
# @Created on : 2016/04/18 15:00
# @Author     : ldf (ldf@eehello.com)
# @Link       : http://www.eehello.com
# @Version    :
# 本程序在python2.7下测试通过
'''

class Province(object):
    memo = '中国的23个省之一'

    def __init__(self, name, capital, leader, flag):

        self.Name = name
        self.Capital = capital
        self.Leader = leader

        self.__Thailand = flag

    def sports_meet(self):
        print self.Name + '正在开运动会'


    @staticmethod
    def Foo():
        print '每个省要带头反腐'

    @property
    def Bar(self):
        return 'sonmthing'

    def show(self):
        print self.__Thailand


    def __sha(self):
        print '我是alex'

    def Foo2(self):
        self.__sha()

#只读
    @property
    def Thailand(self):
        return self.__Thailand

#可改
    @Thailand.setter
    def Thailand(self,value):
        self.__Thailand = value

#hb = Province('河北','石家庄','李杨')

japan = Province('日本','济南','王胜辉',True)
#print japan.__Thailand
#japan.show()
#print Province.Foo()
#print japan.Bar
#japan.Foo2()

#print japan.Thailand
#print japan.Thailand
#japan.Thailand = False
#print japan.Thailand

'''
class test1:
    def __init__(self):
        self.__pravite = 'alex 1'

    @property
    def show(self):
        return self.__pravite

class test2(object):
    def _init__(self):
        self.__pravite = 'alex 2'

    @property
    def show(self):
        return self.__pravite

    @show.setter
    def show(self,value):
        return self.__pravite

t1 = test1()
print t1.show

t1.show = 'alex 2'
print t1.show

t2 = test2()
print test2.show
test2.show = 'alex 3'
print t2.show


class Foo:
    def __init__(self):
        pass

    def __del__(self):
        print 'it is del !'

    def GO(self):
        print 'go'

    def __call__(self):
        print 'call'


#f1 = Foo()
#f1.GO()

import time
#time.sleep(10)

#f1()
Foo()()
'''
'''
class father:

    def __init__(self):
        self.Fname = 'ffff'
        print 'father.__init__'
    def func(self):
        print 'father.func'

    def bad(self):
        print 'father.chouyanhejiu'

class son(father):
    def __init__(self):

        self.Sname = 'ssssssssss'
        print 'son.__init__'
        father.__init__(self)
#        super(son).__init__()

    def bar(self):
        print 'son.bar'
#重写bad
#    def bad(self):
#        print 'son.chouyan'
    def bad(self):
        father.bad(self)
        print 'son.dubo'

s1 = son()
s1.bar()
s1.func()
s1.bad()
'''


class test001(object):

    def a(self):
        self.aa = 0
        self._a = 1
        print(self._a)

    def b(self):

        self.__b = 2
        print(self.__b)

    def c(self):
        print(self.aa)
        print(self._a)
        print(self.__b)



t1 = test001()

t1.a()
t1.b()
t1.c()







